# $Id: PKGBUILD 87001 2013-03-25 19:16:40Z bpiotrowski $
# Maintainer: Dale Blount <dale@archlinux.org>

pkgname=fssos-nsvs
pkgver=0.5
pkgrel=10
pkgdesc="NSVS for FSSOS"
arch=('i686' 'x86_64')
url="http://fssos.sourceforge.net/"
license=('GPL')
depends=('bash' 'mariadb')
backup=('etc/nsvsd.conf')
options=('!libtool' '!makeflags')
install=$pkgname.install
source=("http://downloads.sourceforge.net/sourceforge/fssos/nsvs-$pkgver.tar.gz"
        'nsvsd'
	'nsvsd.service')

build() {
  cd $srcdir/nsvs-$pkgver
  ./configure --prefix=/usr --sysconfdir=/etc
  make CFLAGS="${CFLAGS} -D_GNU_SOURCE"
}

package() {
  cd $srcdir/nsvs-$pkgver
  make DESTDIR=$pkgdir install
  install -D -m755 "$srcdir/nsvsd" "$pkgdir/etc/rc.d/nsvsd"
  install -D -m644 "$srcdir/nsvsd.service" "$pkgdir/usr/lib/systemd/system/nsvsd.service"
}
md5sums=('3f17c2f6339f1a322b712b467023d825'
         '4dfd9dc0d69b375587e39ab2621d9ea9'
         '61e970d0704875b1da83cb4e9fc0eef5')
